package com.spic.business.registrationform.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.spic.business.registrationform.mapper.ArchiveStaffJobholderRecordsMapper;
import com.spic.business.registrationform.domain.ArchiveStaffJobholderRecords;
import com.spic.business.registrationform.service.IArchiveStaffJobholderRecordsService;

/**
 * 从业人员安全培训、考核记录Service业务层处理
 * 
 * @author spic
 * @date 2022-07-20
 */
@Service
public class ArchiveStaffJobholderRecordsServiceImpl implements IArchiveStaffJobholderRecordsService 
{
    @Autowired
    private ArchiveStaffJobholderRecordsMapper archiveStaffJobholderRecordsMapper;

    /**
     * 查询从业人员安全培训、考核记录
     * 
     * @param studyId 从业人员安全培训、考核记录主键
     * @return 从业人员安全培训、考核记录
     */
    @Override
    public ArchiveStaffJobholderRecords selectArchiveStaffJobholderRecordsByStudyId(Long studyId)
    {
        return archiveStaffJobholderRecordsMapper.selectArchiveStaffJobholderRecordsByStudyId(studyId);
    }

    /**
     * 查询从业人员安全培训、考核记录列表
     * 
     * @param archiveStaffJobholderRecords 从业人员安全培训、考核记录
     * @return 从业人员安全培训、考核记录
     */
    @Override
    public List<ArchiveStaffJobholderRecords> selectArchiveStaffJobholderRecordsList(ArchiveStaffJobholderRecords archiveStaffJobholderRecords)
    {
        return archiveStaffJobholderRecordsMapper.selectArchiveStaffJobholderRecordsList(archiveStaffJobholderRecords);
    }

    /**
     * 新增从业人员安全培训、考核记录
     * 
     * @param archiveStaffJobholderRecords 从业人员安全培训、考核记录
     * @return 结果
     */
    @Override
    public int insertArchiveStaffJobholderRecords(ArchiveStaffJobholderRecords archiveStaffJobholderRecords)
    {
        return archiveStaffJobholderRecordsMapper.insertArchiveStaffJobholderRecords(archiveStaffJobholderRecords);
    }

    /**
     * 修改从业人员安全培训、考核记录
     * 
     * @param archiveStaffJobholderRecords 从业人员安全培训、考核记录
     * @return 结果
     */
    @Override
    public int updateArchiveStaffJobholderRecords(ArchiveStaffJobholderRecords archiveStaffJobholderRecords)
    {
        return archiveStaffJobholderRecordsMapper.updateArchiveStaffJobholderRecords(archiveStaffJobholderRecords);
    }

    /**
     * 批量删除从业人员安全培训、考核记录
     * 
     * @param studyIds 需要删除的从业人员安全培训、考核记录主键
     * @return 结果
     */
    @Override
    public int deleteArchiveStaffJobholderRecordsByStudyIds(Long[] studyIds)
    {
        return archiveStaffJobholderRecordsMapper.deleteArchiveStaffJobholderRecordsByStudyIds(studyIds);
    }

    /**
     * 删除从业人员安全培训、考核记录信息
     * 
     * @param studyId 从业人员安全培训、考核记录主键
     * @return 结果
     */
    @Override
    public int deleteArchiveStaffJobholderRecordsByStudyId(Long studyId)
    {
        return archiveStaffJobholderRecordsMapper.deleteArchiveStaffJobholderRecordsByStudyId(studyId);
    }

    @Override
    public int deleteArchiveStaffJobholderRecordsByStaffArchiveIds(String[] staffArchiveIds) {
        return archiveStaffJobholderRecordsMapper.deleteArchiveStaffJobholderRecordsByStaffArchiveIds(staffArchiveIds);
    }
}
